#include "mainwindow.h"
#include "ui_mainwindow.h"
#include<Windows.h>
#include<QProcess>
#include<QSound>
MainWindow::MainWindow(QWidget *parent)
    : QMainWindow(parent)
    , ui(new Ui::MainWindow)
{
    ui->setupUi(this);
    this->setWindowIcon(QIcon(":/img/icon.jpg"));
//    setStyleSheet("background-color:qlineargradient(spread:pad, x1:0, y1:0, x2:0, y2:1, stop:0 #8386ec,stop:0.5 #474ac1 ,stop:1 #22259f)");
    ui->label_2->setVisible(false);
    ui->label_3->setVisible(false);
    ui->pushButton_player->setStyleSheet("QPushButton{border-image: url(:/btn_play_1.png)}"
                                         "QPushButton:hover {border-image: url(:/btn_play_2.png)}"
                                         "QPushButton:checked {border-image: url(:/btn_pause_1.png)}"
                                         "QPushButton:checked:hover {border-image: url(:/btn_pause_2.png)}");
    ui->pushButton_player->setCheckable(true);
    ui->pushButton_trans->setStyleSheet("QPushButton{background-color: rgb(170, 170, 255);font: 10pt KaiTi;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                              "QPushButton:hover{background-color:rgb(229, 241, 251); color: black;}"
                                              "QPushButton:pressed{background-color:rgb(204, 228, 247);border-style: inset;}");
    ui->pushButton_report->setStyleSheet("QPushButton{background-color: rgb(170, 170, 255);font: 8pt KaiTi;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                              "QPushButton:hover{background-color:rgb(229, 241, 251); color: black;}"
                                              "QPushButton:pressed{background-color:rgb(204, 228, 247);border-style: inset;}");
    ui->pushButton_html->setStyleSheet("QPushButton{background-color: rgb(170, 170, 255);font: 10pt KaiTi;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                              "QPushButton:hover{background-color:rgb(229, 241, 251); color: black;}"
                                              "QPushButton:pressed{background-color:rgb(204, 228, 247);border-style: inset;}");
    ui->pushButton_choose->setStyleSheet("QPushButton{background-color: rgb(170, 170, 255);font: 10pt KaiTi;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                              "QPushButton:hover{background-color:rgb(229, 241, 251); color: black;}"
                                              "QPushButton:pressed{background-color:rgb(204, 228, 247);border-style: inset;}");
    ui->pushButton_A0->setStyleSheet("QPushButton{background-color: white;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                              "QPushButton:hover{background-color:rgb(229, 241, 251); color: black;}"
                                              "QPushButton:pressed{background-color:rgb(204, 228, 247);border-style: inset;}");
    ui->pushButton_B0->setStyleSheet("QPushButton{background-color: white;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                              "QPushButton:hover{background-color:rgb(229, 241, 251); color: black;}"
                                              "QPushButton:pressed{background-color:rgb(204, 228, 247);border-style: inset;}");

    ui->pushButton_C1->setStyleSheet("QPushButton{background-color: white;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                              "QPushButton:hover{background-color:rgb(229, 241, 251); color: black;}"
                                              "QPushButton:pressed{background-color:rgb(204, 228, 247);border-style: inset;}");
    ui->pushButton_D1->setStyleSheet("QPushButton{background-color: white;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                              "QPushButton:hover{background-color:rgb(229, 241, 251); color: black;}"
                                              "QPushButton:pressed{background-color:rgb(204, 228, 247);border-style: inset;}");
    ui->pushButton_E1->setStyleSheet("QPushButton{background-color: white;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                              "QPushButton:hover{background-color:rgb(229, 241, 251); color: black;}"
                                              "QPushButton:pressed{background-color:rgb(204, 228, 247);border-style: inset;}");
    ui->pushButton_F1->setStyleSheet("QPushButton{background-color: white;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                              "QPushButton:hover{background-color:rgb(229, 241, 251); color: black;}"
                                              "QPushButton:pressed{background-color:rgb(204, 228, 247);border-style: inset;}");
    ui->pushButton_G1->setStyleSheet("QPushButton{background-color: white;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                              "QPushButton:hover{background-color:rgb(229, 241, 251); color: black;}"
                                              "QPushButton:pressed{background-color:rgb(204, 228, 247);border-style: inset;}");
    ui->pushButton_A1->setStyleSheet("QPushButton{background-color: white;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                              "QPushButton:hover{background-color:rgb(229, 241, 251); color: black;}"
                                              "QPushButton:pressed{background-color:rgb(204, 228, 247);border-style: inset;}");
    ui->pushButton_B1->setStyleSheet("QPushButton{background-color: white;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                              "QPushButton:hover{background-color:rgb(229, 241, 251); color: black;}"
                                              "QPushButton:pressed{background-color:rgb(204, 228, 247);border-style: inset;}");

    ui->pushButton_C2->setStyleSheet("QPushButton{background-color: white;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                              "QPushButton:hover{background-color:rgb(229, 241, 251); color: black;}"
                                              "QPushButton:pressed{background-color:rgb(204, 228, 247);border-style: inset;}");
    ui->pushButton_D2->setStyleSheet("QPushButton{background-color: white;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                              "QPushButton:hover{background-color:rgb(229, 241, 251); color: black;}"
                                              "QPushButton:pressed{background-color:rgb(204, 228, 247);border-style: inset;}");
    ui->pushButton_E2->setStyleSheet("QPushButton{background-color: white;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                              "QPushButton:hover{background-color:rgb(229, 241, 251); color: black;}"
                                              "QPushButton:pressed{background-color:rgb(204, 228, 247);border-style: inset;}");
    ui->pushButton_F2->setStyleSheet("QPushButton{background-color: white;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                              "QPushButton:hover{background-color:rgb(229, 241, 251); color: black;}"
                                              "QPushButton:pressed{background-color:rgb(204, 228, 247);border-style: inset;}");
    ui->pushButton_G2->setStyleSheet("QPushButton{background-color: white;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                              "QPushButton:hover{background-color:rgb(229, 241, 251); color: black;}"
                                              "QPushButton:pressed{background-color:rgb(204, 228, 247);border-style: inset;}");
    ui->pushButton_A2->setStyleSheet("QPushButton{background-color: white;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                              "QPushButton:hover{background-color:rgb(229, 241, 251); color: black;}"
                                              "QPushButton:pressed{background-color:rgb(204, 228, 247);border-style: inset;}");
    ui->pushButton_B2->setStyleSheet("QPushButton{background-color: white;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                              "QPushButton:hover{background-color:rgb(229, 241, 251); color: black;}"
                                              "QPushButton:pressed{background-color:rgb(204, 228, 247);border-style: inset;}");

    ui->pushButton_C3->setStyleSheet("QPushButton{background-color: white;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                              "QPushButton:hover{background-color:rgb(229, 241, 251); color: black;}"
                                              "QPushButton:pressed{background-color:rgb(204, 228, 247);border-style: inset;}");
    ui->pushButton_D3->setStyleSheet("QPushButton{background-color: white;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                              "QPushButton:hover{background-color:rgb(229, 241, 251); color: black;}"
                                              "QPushButton:pressed{background-color:rgb(204, 228, 247);border-style: inset;}");
    ui->pushButton_E3->setStyleSheet("QPushButton{background-color: white;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                              "QPushButton:hover{background-color:rgb(229, 241, 251); color: black;}"
                                              "QPushButton:pressed{background-color:rgb(204, 228, 247);border-style: inset;}");
    ui->pushButton_F3->setStyleSheet("QPushButton{background-color: white;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                              "QPushButton:hover{background-color:rgb(229, 241, 251); color: black;}"
                                              "QPushButton:pressed{background-color:rgb(204, 228, 247);border-style: inset;}");
    ui->pushButton_G3->setStyleSheet("QPushButton{background-color: white;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                              "QPushButton:hover{background-color:rgb(229, 241, 251); color: black;}"
                                              "QPushButton:pressed{background-color:rgb(204, 228, 247);border-style: inset;}");
    ui->pushButton_A3->setStyleSheet("QPushButton{background-color: white;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                              "QPushButton:hover{background-color:rgb(229, 241, 251); color: black;}"
                                              "QPushButton:pressed{background-color:rgb(204, 228, 247);border-style: inset;}");
    ui->pushButton_B3->setStyleSheet("QPushButton{background-color: white;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                              "QPushButton:hover{background-color:rgb(229, 241, 251); color: black;}"
                                              "QPushButton:pressed{background-color:rgb(204, 228, 247);border-style: inset;}");

    ui->pushButton_C4->setStyleSheet("QPushButton{background-color: white;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                              "QPushButton:hover{background-color:rgb(229, 241, 251); color: black;}"
                                              "QPushButton:pressed{background-color:rgb(204, 228, 247);border-style: inset;}");
    ui->pushButton_D4->setStyleSheet("QPushButton{background-color: white;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                              "QPushButton:hover{background-color:rgb(229, 241, 251); color: black;}"
                                              "QPushButton:pressed{background-color:rgb(204, 228, 247);border-style: inset;}");
    ui->pushButton_E4->setStyleSheet("QPushButton{background-color: white;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                              "QPushButton:hover{background-color:rgb(229, 241, 251); color: black;}"
                                              "QPushButton:pressed{background-color:rgb(204, 228, 247);border-style: inset;}");
    ui->pushButton_F4->setStyleSheet("QPushButton{background-color: white;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                              "QPushButton:hover{background-color:rgb(229, 241, 251); color: black;}"
                                              "QPushButton:pressed{background-color:rgb(204, 228, 247);border-style: inset;}");
    ui->pushButton_G4->setStyleSheet("QPushButton{background-color: white;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                              "QPushButton:hover{background-color:rgb(229, 241, 251); color: black;}"
                                              "QPushButton:pressed{background-color:rgb(204, 228, 247);border-style: inset;}");
    ui->pushButton_A4->setStyleSheet("QPushButton{background-color: white;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                              "QPushButton:hover{background-color:rgb(229, 241, 251); color: black;}"
                                              "QPushButton:pressed{background-color:rgb(204, 228, 247);border-style: inset;}");
    ui->pushButton_B4->setStyleSheet("QPushButton{background-color: white;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                              "QPushButton:hover{background-color:rgb(229, 241, 251); color: black;}"
                                              "QPushButton:pressed{background-color:rgb(204, 228, 247);border-style: inset;}");

    ui->pushButton_C5->setStyleSheet("QPushButton{background-color: white;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                              "QPushButton:hover{background-color:rgb(229, 241, 251); color: black;}"
                                              "QPushButton:pressed{background-color:rgb(204, 228, 247);border-style: inset;}");
    ui->pushButton_D5->setStyleSheet("QPushButton{background-color: white;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                              "QPushButton:hover{background-color:rgb(229, 241, 251); color: black;}"
                                              "QPushButton:pressed{background-color:rgb(204, 228, 247);border-style: inset;}");
    ui->pushButton_E5->setStyleSheet("QPushButton{background-color: white;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                              "QPushButton:hover{background-color:rgb(229, 241, 251); color: black;}"
                                              "QPushButton:pressed{background-color:rgb(204, 228, 247);border-style: inset;}");
    ui->pushButton_F5->setStyleSheet("QPushButton{background-color: white;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                              "QPushButton:hover{background-color:rgb(229, 241, 251); color: black;}"
                                              "QPushButton:pressed{background-color:rgb(204, 228, 247);border-style: inset;}");
    ui->pushButton_G5->setStyleSheet("QPushButton{background-color: white;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                              "QPushButton:hover{background-color:rgb(229, 241, 251); color: black;}"
                                              "QPushButton:pressed{background-color:rgb(204, 228, 247);border-style: inset;}");
    ui->pushButton_A5->setStyleSheet("QPushButton{background-color: white;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                              "QPushButton:hover{background-color:rgb(229, 241, 251); color: black;}"
                                              "QPushButton:pressed{background-color:rgb(204, 228, 247);border-style: inset;}");
    ui->pushButton_B5->setStyleSheet("QPushButton{background-color: white;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                              "QPushButton:hover{background-color:rgb(229, 241, 251); color: black;}"
                                              "QPushButton:pressed{background-color:rgb(204, 228, 247);border-style: inset;}");

    ui->pushButton_C6->setStyleSheet("QPushButton{background-color: white;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                              "QPushButton:hover{background-color:rgb(229, 241, 251); color: black;}"
                                              "QPushButton:pressed{background-color:rgb(204, 228, 247);border-style: inset;}");
    ui->pushButton_D6->setStyleSheet("QPushButton{background-color: white;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                              "QPushButton:hover{background-color:rgb(229, 241, 251); color: black;}"
                                              "QPushButton:pressed{background-color:rgb(204, 228, 247);border-style: inset;}");
    ui->pushButton_E6->setStyleSheet("QPushButton{background-color: white;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                              "QPushButton:hover{background-color:rgb(229, 241, 251); color: black;}"
                                              "QPushButton:pressed{background-color:rgb(204, 228, 247);border-style: inset;}");
    ui->pushButton_F6->setStyleSheet("QPushButton{background-color: white;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                              "QPushButton:hover{background-color:rgb(229, 241, 251); color: black;}"
                                              "QPushButton:pressed{background-color:rgb(204, 228, 247);border-style: inset;}");
    ui->pushButton_G6->setStyleSheet("QPushButton{background-color: white;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                              "QPushButton:hover{background-color:rgb(229, 241, 251); color: black;}"
                                              "QPushButton:pressed{background-color:rgb(204, 228, 247);border-style: inset;}");
    ui->pushButton_A6->setStyleSheet("QPushButton{background-color: white;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                              "QPushButton:hover{background-color:rgb(229, 241, 251); color: black;}"
                                              "QPushButton:pressed{background-color:rgb(204, 228, 247);border-style: inset;}");
    ui->pushButton_B6->setStyleSheet("QPushButton{background-color: white;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                              "QPushButton:hover{background-color:rgb(229, 241, 251); color: black;}"
                                              "QPushButton:pressed{background-color:rgb(204, 228, 247);border-style: inset;}");

    ui->pushButton_C7->setStyleSheet("QPushButton{background-color: white;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                              "QPushButton:hover{background-color:rgb(229, 241, 251); color: black;}"
                                              "QPushButton:pressed{background-color:rgb(204, 228, 247);border-style: inset;}");
    ui->pushButton_D7->setStyleSheet("QPushButton{background-color: white;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                              "QPushButton:hover{background-color:rgb(229, 241, 251); color: black;}"
                                              "QPushButton:pressed{background-color:rgb(204, 228, 247);border-style: inset;}");
    ui->pushButton_E7->setStyleSheet("QPushButton{background-color: white;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                              "QPushButton:hover{background-color:rgb(229, 241, 251); color: black;}"
                                              "QPushButton:pressed{background-color:rgb(204, 228, 247);border-style: inset;}");
    ui->pushButton_F7->setStyleSheet("QPushButton{background-color: white;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                              "QPushButton:hover{background-color:rgb(229, 241, 251); color: black;}"
                                              "QPushButton:pressed{background-color:rgb(204, 228, 247);border-style: inset;}");
    ui->pushButton_G7->setStyleSheet("QPushButton{background-color: white;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                              "QPushButton:hover{background-color:rgb(229, 241, 251); color: black;}"
                                              "QPushButton:pressed{background-color:rgb(204, 228, 247);border-style: inset;}");
    ui->pushButton_A7->setStyleSheet("QPushButton{background-color: white;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                              "QPushButton:hover{background-color:rgb(229, 241, 251); color: black;}"
                                              "QPushButton:pressed{background-color:rgb(204, 228, 247);border-style: inset;}");
    ui->pushButton_B7->setStyleSheet("QPushButton{background-color: white;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                              "QPushButton:hover{background-color:rgb(229, 241, 251); color: black;}"
                                              "QPushButton:pressed{background-color:rgb(204, 228, 247);border-style: inset;}");

    ui->pushButton_C8->setStyleSheet("QPushButton{background-color: white;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                              "QPushButton:hover{background-color:rgb(229, 241, 251); color: black;}"
                                              "QPushButton:pressed{background-color:rgb(204, 228, 247);border-style: inset;}");

    ui->pushButton_a0->setStyleSheet("QPushButton{background-color: black;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                     "QPushButton:hover{background-color:gray; color: white;}"
                                     "QPushButton:pressed{background-color:black;border-style: inset;}");

    ui->pushButton_b1->setStyleSheet("QPushButton{background-color: black;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                     "QPushButton:hover{background-color:gray; color: white;}"
                                     "QPushButton:pressed{background-color:black;border-style: inset;}");
    ui->pushButton_c1->setStyleSheet("QPushButton{background-color: black;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                     "QPushButton:hover{background-color:gray; color: white;}"
                                     "QPushButton:pressed{background-color:black;border-style: inset;}");
    ui->pushButton_d1->setStyleSheet("QPushButton{background-color: black;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                     "QPushButton:hover{background-color:gray; color: white;}"
                                     "QPushButton:pressed{background-color:black;border-style: inset;}");
    ui->pushButton_e1->setStyleSheet("QPushButton{background-color: black;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                     "QPushButton:hover{background-color:gray; color: white;}"
                                     "QPushButton:pressed{background-color:black;border-style: inset;}");
    ui->pushButton_f1->setStyleSheet("QPushButton{background-color: black;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                     "QPushButton:hover{background-color:gray; color: white;}"
                                     "QPushButton:pressed{background-color:black;border-style: inset;}");

    ui->pushButton_b2->setStyleSheet("QPushButton{background-color: black;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                     "QPushButton:hover{background-color:gray; color: white;}"
                                     "QPushButton:pressed{background-color:black;border-style: inset;}");
    ui->pushButton_c2->setStyleSheet("QPushButton{background-color: black;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                     "QPushButton:hover{background-color:gray; color: white;}"
                                     "QPushButton:pressed{background-color:black;border-style: inset;}");
    ui->pushButton_d2->setStyleSheet("QPushButton{background-color: black;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                     "QPushButton:hover{background-color:gray; color: white;}"
                                     "QPushButton:pressed{background-color:black;border-style: inset;}");
    ui->pushButton_e2->setStyleSheet("QPushButton{background-color: black;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                     "QPushButton:hover{background-color:gray; color: white;}"
                                     "QPushButton:pressed{background-color:black;border-style: inset;}");
    ui->pushButton_f2->setStyleSheet("QPushButton{background-color: black;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                     "QPushButton:hover{background-color:gray; color: white;}"
                                     "QPushButton:pressed{background-color:black;border-style: inset;}");

    ui->pushButton_b3->setStyleSheet("QPushButton{background-color: black;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                     "QPushButton:hover{background-color:gray; color: white;}"
                                     "QPushButton:pressed{background-color:black;border-style: inset;}");
    ui->pushButton_c3->setStyleSheet("QPushButton{background-color: black;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                     "QPushButton:hover{background-color:gray; color: white;}"
                                     "QPushButton:pressed{background-color:black;border-style: inset;}");
    ui->pushButton_d3->setStyleSheet("QPushButton{background-color: black;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                     "QPushButton:hover{background-color:gray; color: white;}"
                                     "QPushButton:pressed{background-color:black;border-style: inset;}");
    ui->pushButton_e3->setStyleSheet("QPushButton{background-color: black;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                     "QPushButton:hover{background-color:gray; color: white;}"
                                     "QPushButton:pressed{background-color:black;border-style: inset;}");
    ui->pushButton_f3->setStyleSheet("QPushButton{background-color: black;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                     "QPushButton:hover{background-color:gray; color: white;}"
                                     "QPushButton:pressed{background-color:black;border-style: inset;}");

    ui->pushButton_b4->setStyleSheet("QPushButton{background-color: black;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                     "QPushButton:hover{background-color:gray; color: white;}"
                                     "QPushButton:pressed{background-color:black;border-style: inset;}");
    ui->pushButton_c4->setStyleSheet("QPushButton{background-color: black;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                     "QPushButton:hover{background-color:gray; color: white;}"
                                     "QPushButton:pressed{background-color:black;border-style: inset;}");
    ui->pushButton_d4->setStyleSheet("QPushButton{background-color: black;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                     "QPushButton:hover{background-color:gray; color: white;}"
                                     "QPushButton:pressed{background-color:black;border-style: inset;}");
    ui->pushButton_e4->setStyleSheet("QPushButton{background-color: black;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                     "QPushButton:hover{background-color:gray; color: white;}"
                                     "QPushButton:pressed{background-color:black;border-style: inset;}");
    ui->pushButton_f4->setStyleSheet("QPushButton{background-color: black;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                     "QPushButton:hover{background-color:gray; color: white;}"
                                     "QPushButton:pressed{background-color:black;border-style: inset;}");

    ui->pushButton_b5->setStyleSheet("QPushButton{background-color: black;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                     "QPushButton:hover{background-color:gray; color: white;}"
                                     "QPushButton:pressed{background-color:black;border-style: inset;}");
    ui->pushButton_c5->setStyleSheet("QPushButton{background-color: black;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                     "QPushButton:hover{background-color:gray; color: white;}"
                                     "QPushButton:pressed{background-color:black;border-style: inset;}");
    ui->pushButton_d5->setStyleSheet("QPushButton{background-color: black;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                     "QPushButton:hover{background-color:gray; color: white;}"
                                     "QPushButton:pressed{background-color:black;border-style: inset;}");
    ui->pushButton_e5->setStyleSheet("QPushButton{background-color: black;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                     "QPushButton:hover{background-color:gray; color: white;}"
                                     "QPushButton:pressed{background-color:black;border-style: inset;}");
    ui->pushButton_f5->setStyleSheet("QPushButton{background-color: black;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                     "QPushButton:hover{background-color:gray; color: white;}"
                                     "QPushButton:pressed{background-color:black;border-style: inset;}");

    ui->pushButton_b6->setStyleSheet("QPushButton{background-color: black;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                     "QPushButton:hover{background-color:gray; color: white;}"
                                     "QPushButton:pressed{background-color:black;border-style: inset;}");
    ui->pushButton_c6->setStyleSheet("QPushButton{background-color: black;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                     "QPushButton:hover{background-color:gray; color: white;}"
                                     "QPushButton:pressed{background-color:black;border-style: inset;}");
    ui->pushButton_d6->setStyleSheet("QPushButton{background-color: black;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                     "QPushButton:hover{background-color:gray; color: white;}"
                                     "QPushButton:pressed{background-color:black;border-style: inset;}");
    ui->pushButton_e6->setStyleSheet("QPushButton{background-color: black;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                     "QPushButton:hover{background-color:gray; color: white;}"
                                     "QPushButton:pressed{background-color:black;border-style: inset;}");
    ui->pushButton_f6->setStyleSheet("QPushButton{background-color: black;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                     "QPushButton:hover{background-color:gray; color: white;}"
                                     "QPushButton:pressed{background-color:black;border-style: inset;}");

    ui->pushButton_b7->setStyleSheet("QPushButton{background-color: black;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                     "QPushButton:hover{background-color:gray; color: white;}"
                                     "QPushButton:pressed{background-color:black;border-style: inset;}");
    ui->pushButton_c7->setStyleSheet("QPushButton{background-color: black;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                     "QPushButton:hover{background-color:gray; color: white;}"
                                     "QPushButton:pressed{background-color:black;border-style: inset;}");
    ui->pushButton_d7->setStyleSheet("QPushButton{background-color: black;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                     "QPushButton:hover{background-color:gray; color: white;}"
                                     "QPushButton:pressed{background-color:black;border-style: inset;}");
    ui->pushButton_e7->setStyleSheet("QPushButton{background-color: black;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                     "QPushButton:hover{background-color:gray; color: white;}"
                                     "QPushButton:pressed{background-color:black;border-style: inset;}");
    ui->pushButton_f7->setStyleSheet("QPushButton{background-color: black;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                     "QPushButton:hover{background-color:gray; color: white;}"
                                     "QPushButton:pressed{background-color:black;border-style: inset;}");

    // 设置按钮样式及悬浮、按下时的状态
    ui->pushButton_A0->setStyleSheet("QPushButton{background-color: white;border:2px groove gray;border-radius:10px;padding:2px 4px;border-style: outset;}"
                                              "QPushButton:hover{background-color:rgb(229, 241, 251); color: black;}"
                                              "QPushButton:pressed{background-color:rgb(204, 228, 247);border-style: inset;}");
    ui->label->setStyleSheet("background:transparent");
    m_movie=new QMovie(":/img/loading.gif");
    m_movie->setScaledSize(QSize(250,250));
    m_movie->setSpeed(100);
    ui->label->setMovie(m_movie);
    ui->label->setVisible(false);
    m_movie->start();
    ui->label_4->setStyleSheet("background:transparent");
    m_movie2=new QMovie(":/playpiano.gif");
    m_movie2->setScaledSize(QSize(250,250));
    m_movie2->setSpeed(100);
    ui->label_4->setMovie(m_movie2);
    ui->label_4->setVisible(false);
    m_movie2->start();
    player =new QMediaPlayer;
}

MainWindow::~MainWindow()
{
    delete ui;
}



void MainWindow::on_pushButton_C1_clicked()
{
    QSound *bells =new QSound(":/music/Music/1C.wav");
    bells->play();
}


void MainWindow::on_pushButton_D1_clicked()
{
    QSound *bells =new QSound(":/music/Music/1D.wav");
    bells->play();
}


void MainWindow::on_pushButton_E1_clicked()
{
    QSound *bells =new QSound(":/music/Music/1E.wav");
    bells->play();
}

void MainWindow::on_pushButton_F1_clicked()
{
    QSound *bells =new QSound(":/music/Music/1F.wav");
    bells->play();
}

void MainWindow::on_pushButton_G1_clicked()
{
    QSound *bells =new QSound(":/music/Music/1G.wav");
    bells->play();
}

void MainWindow::on_pushButton_A1_clicked()
{
    QSound *bells =new QSound(":/music/Music/2A.wav");
    bells->play();
}

void MainWindow::on_pushButton_B1_clicked()
{
    QSound *bells =new QSound(":/music/Music/2B.wav");
    bells->play();
}

void MainWindow::on_pushButton_b1_clicked()
{
    QSound *bells =new QSound(":/music/Music/1C!.wav");
    bells->play();
}

void MainWindow::on_pushButton_c1_clicked()
{
    QSound *bells =new QSound(":/music/Music/1D!.wav");
    bells->play();
}

void MainWindow::on_pushButton_d1_clicked()
{
    QSound *bells =new QSound(":/music/Music/1F!.wav");
    bells->play();
}

void MainWindow::on_pushButton_e1_clicked()
{
    QSound *bells =new QSound(":/music/Music/1G!.wav");
    bells->play();
}

void MainWindow::on_pushButton_f1_clicked()
{
    QSound *bells =new QSound(":/music/Music/2A!.wav");
    bells->play();
}

void MainWindow::on_pushButton_A0_clicked()
{
    QSound *bells =new QSound(":/music/Music/0A.wav");
    bells->play();
}

void MainWindow::on_pushButton_B0_clicked()
{
    QSound *bells =new QSound(":/music/Music/1B.wav");
    bells->play();
}

void MainWindow::on_pushButton_a0_clicked()
{
    QSound *bells =new QSound(":/music/Music/0A!.wav");
    bells->play();
}

void MainWindow::on_pushButton_trans_clicked()
{
    //清除旧文件
    QFile f1(midifileName),f2(msgfileName),f3(stafffileName);
    if(f1.exists())
    {
        QFile::remove(midifileName);
    }
    if(f2.exists())
    {
        QFile::remove(msgfileName);
    }
    if(f3.exists())
    {
        QFile::remove(stafffileName);
    }
    f1.close();
    f2.close();
    f3.close();
    //开始执行
    ui->label->setVisible(true);
    QProcess process(this);
    QString str = QApplication::applicationDirPath();
    QString str2=str;
    QString str3=str;
    str += "/../../part/PianoTrans/PianoTrans.exe ";
    str +=mp3fileName;
    process.startDetached(str);
    QFile file(midifileName);
    while(true)
    {
        QCoreApplication::processEvents(QEventLoop::AllEvents, 100);
        if(file.exists())
        {
           break;
        }
    }
    file.close();
    str2+="/../../part/midiprint.exe ";
    str2+=midifileName;
    process.startDetached(str2);
    QFile file2(msgfileName);
    while(true)
    {
        QCoreApplication::processEvents(QEventLoop::AllEvents, 100);
        if(file2.exists())
        {
            break;
        }
    }
    file2.close();
    str3+="/../../part/msgtostaff.exe ";
    str3+=msgfileName;
    str3+=" ";
    str3+=stafffileName;
    process.startDetached(str3);
    QFile file3(stafffileName);
    while(true)
    {
        QCoreApplication::processEvents(QEventLoop::AllEvents, 100);
        if(file3.exists())
        {
            break;
        }
    }
    file3.close();
    ui->label->setVisible(false);
    ui->label_3->setText("转换的琴谱："+stafffileName);
    ui->label_3->setVisible(true);
    QFile f5(msgfileName),f4(midifileName);
    if(f4.exists())
    {
        QFile::remove(midifileName);
    }
    if(f5.exists())
    {
        QFile::remove(msgfileName);
    }
    finishmessage(stafffileName);
}

void MainWindow::on_pushButton_C2_clicked()
{
    QSound *bells =new QSound(":/music/Music/2C.wav");
    bells->play();
}

void MainWindow::on_pushButton_D2_clicked()
{
    QSound *bells =new QSound(":/music/Music/2D.wav");
    bells->play();
}

void MainWindow::on_pushButton_E2_clicked()
{
    QSound *bells =new QSound(":/music/Music/2E.wav");
    bells->play();
}

void MainWindow::on_pushButton_F2_clicked()
{
    QSound *bells =new QSound(":/music/Music/2F.wav");
    bells->play();
}

void MainWindow::on_pushButton_G2_clicked()
{
    QSound *bells =new QSound(":/music/Music/2G.wav");
    bells->play();
}

void MainWindow::on_pushButton_A2_clicked()
{
    QSound *bells =new QSound(":/music/Music/3A.wav");
    bells->play();
}

void MainWindow::on_pushButton_B2_clicked()
{
    QSound *bells =new QSound(":/music/Music/3B.wav");
    bells->play();
}

void MainWindow::on_pushButton_C3_clicked()
{
    QSound *bells =new QSound(":/music/Music/3C.wav");
    bells->play();
}

void MainWindow::on_pushButton_D3_clicked()
{
    QSound *bells =new QSound(":/music/Music/3D.wav");
    bells->play();
}

void MainWindow::on_pushButton_E3_clicked()
{
    QSound *bells =new QSound(":/music/Music/3E.wav");
    bells->play();
}

void MainWindow::on_pushButton_F3_clicked()
{
    QSound *bells =new QSound(":/music/Music/3F.wav");
    bells->play();
}

void MainWindow::on_pushButton_G3_clicked()
{
    QSound *bells =new QSound(":/music/Music/3G.wav");
    bells->play();
}

void MainWindow::on_pushButton_A3_clicked()
{
    QSound *bells =new QSound(":/music/Music/4A.wav");
    bells->play();
}

void MainWindow::on_pushButton_B3_clicked()
{
    QSound *bells =new QSound(":/music/Music/4B.wav");
    bells->play();
}

void MainWindow::on_pushButton_C4_clicked()
{
    QSound *bells =new QSound(":/music/Music/4C.wav");
    bells->play();
}

void MainWindow::on_pushButton_D4_clicked()
{
    QSound *bells =new QSound(":/music/Music/4D.wav");
    bells->play();
}

void MainWindow::on_pushButton_E4_clicked()
{
    QSound *bells =new QSound(":/music/Music/4E.wav");
    bells->play();
}

void MainWindow::on_pushButton_F4_clicked()
{
    QSound *bells =new QSound(":/music/Music/4F.wav");
    bells->play();
}

void MainWindow::on_pushButton_G4_clicked()
{
    QSound *bells =new QSound(":/music/Music/4G.wav");
    bells->play();
}

void MainWindow::on_pushButton_A4_clicked()
{
    QSound *bells =new QSound(":/music/Music/5A.wav");
    bells->play();
}

void MainWindow::on_pushButton_B4_clicked()
{
    QSound *bells =new QSound(":/music/Music/5B.wav");
    bells->play();
}

void MainWindow::on_pushButton_C5_clicked()
{
    QSound *bells =new QSound(":/music/Music/5C.wav");
    bells->play();
}

void MainWindow::on_pushButton_D5_clicked()
{
    QSound *bells =new QSound(":/music/Music/5D.wav");
    bells->play();
}

void MainWindow::on_pushButton_E5_clicked()
{
    QSound *bells =new QSound(":/music/Music/5E.wav");
    bells->play();
}

void MainWindow::on_pushButton_F5_clicked()
{
    QSound *bells =new QSound(":/music/Music/5F.wav");
    bells->play();
}

void MainWindow::on_pushButton_G5_clicked()
{
    QSound *bells =new QSound(":/music/Music/5G.wav");
    bells->play();
}

void MainWindow::on_pushButton_A5_clicked()
{
    QSound *bells =new QSound(":/music/Music/6A.wav");
    bells->play();
}

void MainWindow::on_pushButton_B5_clicked()
{
    QSound *bells =new QSound(":/music/Music/6B.wav");
    bells->play();
}

void MainWindow::on_pushButton_C6_clicked()
{
    QSound *bells =new QSound(":/music/Music/6C.wav");
    bells->play();
}

void MainWindow::on_pushButton_D6_clicked()
{
    QSound *bells =new QSound(":/music/Music/6D.wav");
    bells->play();
}

void MainWindow::on_pushButton_E6_clicked()
{
    QSound *bells =new QSound(":/music/Music/6E.wav");
    bells->play();
}

void MainWindow::on_pushButton_F6_clicked()
{
    QSound *bells =new QSound(":/music/Music/6F.wav");
    bells->play();
}

void MainWindow::on_pushButton_G6_clicked()
{
    QSound *bells =new QSound(":/music/Music/6G.wav");
    bells->play();
}

void MainWindow::on_pushButton_A6_clicked()
{
    QSound *bells =new QSound(":/music/Music/7A.wav");
    bells->play();
}

void MainWindow::on_pushButton_B6_clicked()
{
    QSound *bells =new QSound(":/music/Music/7B.wav");
    bells->play();
}

void MainWindow::on_pushButton_C7_clicked()
{
    QSound *bells =new QSound(":/music/Music/7C.wav");
    bells->play();
}

void MainWindow::on_pushButton_D7_clicked()
{
    QSound *bells =new QSound(":/music/Music/7D.wav");
    bells->play();
}

void MainWindow::on_pushButton_E7_clicked()
{
    QSound *bells =new QSound(":/music/Music/7E.wav");
    bells->play();
}

void MainWindow::on_pushButton_F7_clicked()
{
    QSound *bells =new QSound(":/music/Music/7F.wav");
    bells->play();
}

void MainWindow::on_pushButton_G7_clicked()
{
    QSound *bells =new QSound(":/music/Music/7G.wav");
    bells->play();
}

void MainWindow::on_pushButton_A7_clicked()
{
    QSound *bells =new QSound(":/music/Music/8A.wav");
    bells->play();
}

void MainWindow::on_pushButton_B7_clicked()
{
    QSound *bells =new QSound(":/music/Music/8B.wav");
    bells->play();
}

void MainWindow::on_pushButton_C8_clicked()
{
    QSound *bells =new QSound(":/music/Music/8C.wav");
    bells->play();
}

void MainWindow::on_pushButton_b2_clicked()
{
    QSound *bells =new QSound(":/music/Music/2C!.wav");
    bells->play();
}

void MainWindow::on_pushButton_c2_clicked()
{
    QSound *bells =new QSound(":/music/Music/2D!.wav");
    bells->play();
}

void MainWindow::on_pushButton_d2_clicked()
{
    QSound *bells =new QSound(":/music/Music/2F!.wav");
    bells->play();
}

void MainWindow::on_pushButton_e2_clicked()
{
    QSound *bells =new QSound(":/music/Music/2G!.wav");
    bells->play();
}

void MainWindow::on_pushButton_f2_clicked()
{
    QSound *bells =new QSound(":/music/Music/3A!.wav");
    bells->play();
}

void MainWindow::on_pushButton_b3_clicked()
{
    QSound *bells =new QSound(":/music/Music/3C!.wav");
    bells->play();
}

void MainWindow::on_pushButton_c3_clicked()
{
    QSound *bells =new QSound(":/music/Music/3D!.wav");
    bells->play();
}

void MainWindow::on_pushButton_d3_clicked()
{
    QSound *bells =new QSound(":/music/Music/3F!.wav");
    bells->play();
}

void MainWindow::on_pushButton_e3_clicked()
{
    QSound *bells =new QSound(":/music/Music/3G!.wav");
    bells->play();
}

void MainWindow::on_pushButton_f3_clicked()
{
    QSound *bells =new QSound(":/music/Music/4A!.wav");
    bells->play();
}

void MainWindow::on_pushButton_b4_clicked()
{
    QSound *bells =new QSound(":/music/Music/4C!.wav");
    bells->play();
}

void MainWindow::on_pushButton_c4_clicked()
{
    QSound *bells =new QSound(":/music/Music/4D!.wav");
    bells->play();
}

void MainWindow::on_pushButton_d4_clicked()
{
    QSound *bells =new QSound(":/music/Music/4F!.wav");
    bells->play();
}

void MainWindow::on_pushButton_e4_clicked()
{
    QSound *bells =new QSound(":/music/Music/4G!.wav");
    bells->play();
}

void MainWindow::on_pushButton_f4_clicked()
{
    QSound *bells =new QSound(":/music/Music/5A!.wav");
    bells->play();
}

void MainWindow::on_pushButton_b5_clicked()
{
    QSound *bells =new QSound(":/music/Music/5C!.wav");
    bells->play();
}

void MainWindow::on_pushButton_c5_clicked()
{
    QSound *bells =new QSound(":/music/Music/5D!.wav");
    bells->play();
}

void MainWindow::on_pushButton_d5_clicked()
{
    QSound *bells =new QSound(":/music/Music/5F!.wav");
    bells->play();
}

void MainWindow::on_pushButton_e5_clicked()
{
    QSound *bells =new QSound(":/music/Music/5G!.wav");
    bells->play();
}

void MainWindow::on_pushButton_f5_clicked()
{
    QSound *bells =new QSound(":/music/Music/6A!.wav");
    bells->play();
}

void MainWindow::on_pushButton_b6_clicked()
{
    QSound *bells =new QSound(":/music/Music/6C!.wav");
    bells->play();
}

void MainWindow::on_pushButton_c6_clicked()
{
    QSound *bells =new QSound(":/music/Music/6D!.wav");
    bells->play();
}

void MainWindow::on_pushButton_d6_clicked()
{
    QSound *bells =new QSound(":/music/Music/6F!.wav");
    bells->play();
}

void MainWindow::on_pushButton_e6_clicked()
{
    QSound *bells =new QSound(":/music/Music/6G!.wav");
    bells->play();
}

void MainWindow::on_pushButton_f6_clicked()
{
    QSound *bells =new QSound(":/music/Music/7A!.wav");
    bells->play();
}

void MainWindow::on_pushButton_b7_clicked()
{
    QSound *bells =new QSound(":/music/Music/7C!.wav");
    bells->play();
}

void MainWindow::on_pushButton_c7_clicked()
{
    QSound *bells =new QSound(":/music/Music/7D!.wav");
    bells->play();
}

void MainWindow::on_pushButton_d7_clicked()
{
    QSound *bells =new QSound(":/music/Music/7F!.wav");
    bells->play();
}

void MainWindow::on_pushButton_e7_clicked()
{
    QSound *bells =new QSound(":/music/Music/7G!.wav");
    bells->play();
}

void MainWindow::on_pushButton_f7_clicked()
{
    QSound *bells =new QSound(":/music/Music/8A!.wav");
    bells->play();
}

void MainWindow::on_pushButton_html_clicked()
{
    QString str = QApplication::applicationDirPath();

    QDesktopServices::openUrl(QUrl(str+"/../../part/print_staves/print_staves.html"));
}

void finishmessage(QString stafffilename)
{
    //定义一个提示对话框
    QMessageBox button(QMessageBox::Warning, QString("转换完成"),"转换后的五线谱保存为:"+stafffilename);
    button.setStandardButtons (QMessageBox::Yes);
    button.setButtonText (QMessageBox::Yes,QString("确定"));
    int res= button.exec();
    if(res == QMessageBox::Yes)//点击返回
    {
        return;
    }
}

void MainWindow::on_pushButton_choose_clicked()
{
    //定义文件对话框类
    QFileDialog *fileDialog = new QFileDialog(this);
    //定义文件对话框标题
    fileDialog->setWindowTitle(QStringLiteral("选择文件"));
    //设置打开的文件路径
    fileDialog->setDirectory("./");
    //设置文件过滤器,只显示.ui .cpp 文件,多个过滤文件使用空格隔开
    fileDialog->setNameFilter(tr("File(*.mp3)"));
    //设置可以选择多个文件,默认为只能选择一个文件QFileDialog::ExistingFiles
    fileDialog->setFileMode(QFileDialog::ExistingFiles);
    //设置视图模式
    fileDialog->setViewMode(QFileDialog::Detail);
    //获取选择的文件的路径
    if (fileDialog->exec()== QDialog::Accepted)
    {
        QString fileName = fileDialog->selectedFiles()[0];
        qDebug()<<fileName;
        mp3fileName=fileName;
        midifileName=fileName+".mid";
        msgfileName=midifileName+"toMsg.txt";
        stafffileName=midifileName+"toStaff.txt";
        ui->label_2->setText("选择的音频："+mp3fileName);
        ui->label_2->setVisible(true);
        ui->label_3->setVisible(false);
        player->setMedia(QUrl::fromLocalFile(mp3fileName.replace("/","\\")));
        player->setVolume(50);
    }
}



void MainWindow::on_pushButton_player_clicked(bool checked)
{
    if(checked)
    {
        if(mp3fileName!=NULL)
        {
              player->play();
              ui->label_4->setVisible(true);
        }
    }
    else
    {
        player->pause();
        ui->label_4->setVisible(false);
    }
}



void MainWindow::on_pushButton_report_clicked()
{
    QDesktopServices::openUrl(QUrl("https://gitee.com/chen-penghan/soft-worker-fishing/issues"));
}
